package com.liang.blog.controller;

import com.liang.blog.model.TechOption;
import com.liang.blog.service.OptionService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.Mapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Slf4j
@RequestMapping("/option")
@RestController
public class OptionController {
    @Autowired
    private OptionService optionService;
    @RequestMapping("/getOptions")
    public List<TechOption> getOptions() {
        return optionService.getOptions();
    }
}
